SELECT
<#switch (object__id!)>
	<#case "beginDate">
T.BEGIN_DATE AS beginDate
	<#break>
	<#case "endDate">
T.END_DATE AS endDate
	<#break>
	<#case "id">
T.ID AS id
	<#break>
	<#case "roleId">
T.ROLE_ID AS roleId
	<#break>
	<#case "userGroupId">
T.USER_GROUP_ID AS userGroupId
	<#break>
	<#default>
COUNT(1) AS COUNT_
</#switch>
FROM C1_US_GROUP_ROLE T
<#include "whereByCode.ftl">